package com.juc;

import lombok.extern.slf4j.Slf4j;

@Slf4j(topic = "c.Test3")
public class Test3 {

    public static void main(String[] args) {

        Runnable runnable = new Runnable() {

            @Override
            public void run() {
                int num=0;
                while(true) {
                    num++;
                }
            }
        } ;

        Thread t1 = new Thread(runnable,"thread1");
        Thread t2 = new Thread(runnable,"thread2");

        t1.start();
        t2.start();

    }
}
